<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http:www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<include file="Common:cssjs" />
</head>
<body>
<div class="subnav">
  <div class="content-menu ib-a blue line-x"> <a href='{:U("Urlrule/index")}' class="on"><em>URL规则管理</em></a><span>|</span><a class="add fb" href="{:U("Urlrule/add")}"><em>添加规则</em></a> </div>
</div>
<style type="text/css">
	html{_overflow-y:scroll}
</style>
<script type="text/javascript">
<!--
	$(function(){
		$.formValidator.initConfig({formid:"myform",autotip:true,onerror:function(msg,obj){
			 art.dialog.through({
				content:msg,
				lock:true,
				ok:function(){
					this.close();$(obj).focus();
				}
			})
		}});
		$("#file").formValidator({onshow:"请输入URL规则名称",onfocus:"请输入URL规则名称"}).regexValidator({regexp:"^([a-zA-Z0-9]|[_]){0,20}$",onerror:"目录名称必须为字母、数字、下划线、中划线"}).inputValidator({min:1,onerror:"请输入URL规则名称"});
		$("#example").formValidator({onshow:"请输入URL示例",onfocus:"请输入URL示例"}).inputValidator({min:1,onerror:"请输入URL示例"});
		$("#urlrule").formValidator({onshow:"请输入URL规则",onfocus:"请输入URL规则"}).inputValidator({min:1,onerror:"请输入URL规则"});
	})
//-->
</script>
<style type="text/css">
.input-botton {
	border:none;
	border-bottom:1px dotted #E1A035;
	background:none;
}
</style>
<form action="{:U("Urlrule/edit")}" method="post" name="myform" id="myform">
<div class="pad_10">
  <table width="100%" cellpadding="2" cellspacing="1" class="table_form">
      <tr>
        <th width="100">URL规则名称 :</th>
        <td><input type="text" name="file" id="file" size="20" value="{$data.file}"></td>
      </tr>
      <tr>
        <th>模块名称 :</th>
        <td><select name='module' id='module'>
            <option value="content" <if condition="$data['module'] eq 'content' ">selected</if>>内容模块</option>
            <option value="tags" <if condition="$data['module'] eq 'tags' ">selected</if>>Tags模块</option>
          </select></td>
      </tr>
      <tr>
        <th>是否生成静态？ :</th>
        <td><input type="radio" value="1" name="ishtml" <if condition="$data['ishtml'] eq '1' "> checked</if>/>
          是
          <input type="radio" value="0" name="ishtml" <if condition="$data['ishtml'] eq '0' "> checked</if> />
          否 </td>
      </tr>
      <tr>
        <th>URL示例 :</th>
        <td><input type="text" name="example" id="example" size="70" value="{$data.example}"></td>
      </tr>
      <tr>
        <th>URL规则 :</th>
        <td><input type="text" name="urlrule" id="urlrule" value="{$data.urlrule}" size="70"></td>
      </tr>
      <tr>
        <th>可用变量 :</th>
        <td>父栏目路径：
          <input type="text" name="f1" value="<literal>{$categorydir}</literal> " size="15" class="input-botton">
          ，栏目目录：
          <input type="text" name="f1" value="<literal>{$catdir}</literal>" size="10" class="input-botton">
          <div class="bk6"></div>
          年：
          <input type="text" name="f1" value="<literal>{$year}</literal>" size="7" class="input-botton">
          月：
          <input type="text" name="f1" value="<literal>{$month}</literal>" size="9" class="input-botton">
          ，日：
          <input type="text" name="f1" value="<literal>{$day}</literal>" size="7" class="input-botton">
          ID：
          <input type="text" name="f1" value="<literal>{$id}</literal>" size="4" class="input-botton">
          ， 分页：
          <input type="text" name="f1" value="<literal>{$page}</literal>" size="7" class="input-botton"></td>
      </tr>
  </table>
  <div class="bk15"></div>
  <input type="hidden" name="urlruleid" id="urlruleid" value="{$data.urlruleid}">
  <input name="dosubmit" type="submit" value="提交" class="button">
</div>
</form>
</body>
</html>